def prostoe(A):
    for i in range(10):
        if A&2-1!=0:
            print("Не простое")
            break

A=list(input().split())
z=0
x=0
c=0
slov=["zero", "one", "two", "three", "four", "five", "six", "seven", "eight", "nine"]

if len(A)==3                :
    for i in range(3):
        if A[i] not in slov:
            print("Wrong input")
else:
    print("Wrong input")
for i in range(10):
    if A[0]==slov[i]:
        z=100*i
    if A[1]==slov[i]:
        x=10*i
    if A[2]==slov[i]:
        c=i*1
A=z+x+c
print(A)
